import Vue from 'vue'
import App from './App'
import router from './routes/router'
// import store from './store/index'
import VueI18n from 'vue-i18n'
import Lang from './locale'

let language = localStorage.getItem('language') || 'zh'

Vue.config.productionTip = false

Vue.use(VueI18n)
Vue.locale = () => {}

Vue.config.lang = language

const messages = {
  zh: Lang.zh,
  en: Lang.en
}

const i18n = new VueI18n({
  locale: Vue.config.lang,
  messages
})

new Vue({
  router,
  // store,
  i18n,
  render: h => h(App)
}).$mount('#app')
